package weidian;

import java.util.Scanner;

/**
 * @author xizizzz
 * @description: TODO
 * @date 2021-9-18下午 12:43
 */
public class Test1 {
    public static void main(String[] args) {
        final Scanner sc = new Scanner(System.in);
        String str1 = sc.nextLine();
        String str2 = sc.nextLine();
        int index = 0;
        for (int i = 0; i < str1.length(); i++) {
            if (str1.charAt(i) == str2.charAt(index)) {
                index++;
            }

            if (index == (str2.length())) {
                break;
            }
        }
        if (index == (str2.length())) {
            System.out.println("yes");
        } else {
            System.out.println("no");
        }
    }
}
